#include<time.h>
#include<stdio.h>
#define N 30000
main()//唐子豪
{
    float x,y;
    int c=0,d=0;
    randomize();
    while(c++<=N){
        x=random(101);
        y=ramdom(101);
        if(x*x+y*y<=10000)
            d++
    }
    printf("pi=%f\n",4.*d/N);
}